package com.hs.srm.admin.modules.harmfulsubstance.dao;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.hs.srm.admin.modules.harmfulsubstance.entity.ReportRepositoryEntity;
import com.hs.srm.admin.modules.vendor.vo.VendorCertificateVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 报告库表数据库访问层
 *
 * @author ych
 * @since 2020-03-17 16:42:42
 */
public interface ReportRepositoryDao extends BaseMapper<ReportRepositoryEntity> {

    List<ReportRepositoryEntity> selectBatchCodes(@Param("codes") String[] codes, @Param("vendorCode") String vendorCode);

    int setExpiredValid(String now);

    int setWarningValid(String after);

    ReportRepositoryEntity reportDataByCode(@Param("vendorCode") String vendorCode, @Param("reportCode") String reportCode);

    //通过供应商代码查询资质证书
    List<VendorCertificateVO> findFilePath(String vendorCode);
}